<!-- 导航URL -->
<div class="row wrapper border-bottom white-bg page-heading">
    <div class="col-md-12">
        <ol class="breadcrumb">
            <li><a href="index.html">主页</a></li>
            <li>超级银行家</li>
            <li class="active"><strong>保单总奖金管理</strong></li>
        </ol>
    </div>
</div>
<!-- 主要内容 -->
<div class="wrapper wrapper-content animated fadeIn" ng-controller="insuranceBonusCtrl">
    <form class="form-horizontal" id="form1">
        <div class="row">
            <div class="col-lg-12">
                <div class="panel-body ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>保单总奖金管理</h5>
                    </div>

                    <div class="ibox-content">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">组织：</label>
                            <div class="" style="float:left;height:40px;line-height:40px;width: 180px">
                                <select  chosen="{width:'100%'}" id="autocomplete-select1" class="chosen-select" tabindex="7" ng-model="baseInfo.orgId" ng-options="org.orgId as org.orgName for org in orgInfoList">
                                </select>
                            </div>
                            <label class="col-sm-2 control-label">保险公司别称：</label>
                            <div class="" style="float:left;height:40px;line-height:40px;width: 180px">
                                <select  chosen="{width:'100%'}" id="autocomplete-select2" class="chosen-select" tabindex="7" ng-model="baseInfo.companyNo" ng-options="org.companyNo as org.companyNickName for org in companyListAll">
                                </select>
                            </div>

                        </div>
                        <div class="ibox-content">
                            <div class="form-group">
                                <label class="col-sm-2 control-label">产品名称：</label>
                                <div class="" style="float:left;height:40px;line-height:40px;width: 180px">
                                    <select  chosen="{width:'100%'}" id="autocomplete-select3" class="chosen-select" tabindex="7" ng-model="baseInfo.productId" ng-options="org.productId as org.productName for org in productListAll">
                                    </select>
                                </div>
                            </div>
                        </div>
                        
                        <div class="form-group" style="margin-top: 30px">
                            <label class="col-sm-2 control-label"></label>
                            <div class="col-sm-8">
                                <button class="btn btn-primary6 btn-mr20"  ng-click="query()" ng-disabled="submitting">查询</button>
                                <button class="btn btn-primary5 btn-mr20" type="button" 
                                        ng-click="addInsurance()">新增</button>
                            </div>
                        </div>
                    </div>
                </div>

                <div class="panel-body ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>列表</h5>
                    </div>
                    <div class="ibox-content">
                        <div class="tposition">
                            <div class="gridStyle" ui-grid="orgInfoGrid" ui-grid-selection ui-grid-pagination
                                 ui-grid-resize-columns ui-grid-pinning></div>
                            <div ng-show="loadImg" class="timg"></div>
                        </div>
                    </div>
                </div>
                <div style="height:30px;"></div>
            </div>
        </div>
    </form>

    <div id="addInsurance" class="modal fade" tabindex="3" role="dialog">
        <form class="form-horizontal" name="horizontal" >
			<div class="modal-dialog" style="height:400px;width: 900px">
				<div class="modal-content" style="height:400px;width: 900px">

                    <div class="outDiv" style="clear:left;margin-top:20px;">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>所属组织：</label>
                        <div class="col-sm-3">
                                <select chosen="{width:'100%'}" id="autocomplete-select5" class="chosen-select" tabindex="3" ng-model="baseInfo.orgId" ng-options="org.orgId as org.orgName for org in orgInfoListAll">
                                </select>
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>保险公司别称：</label>
                        <div class="col-sm-3" >
                            <select chosen="{width:'100%'}" id="autocomplete-select6" class="chosen-select" tabindex="3" ng-change="companyChange(baseInfo.companyNo)" ng-model="baseInfo.companyNo" ng-options="org.companyNo as org.companyNickName for org in companyList">
                            </select>
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>产品名称：</label>
                        <div class="col-sm-3" >
                            <select chosen="{width:'100%'}" id="autocomplete-select7" class="chosen-select" tabindex="3" ng-change="productChange(baseInfo.productId)" ng-model="baseInfo.productId" ng-options="org.productId as org.productName for org in productList">
                            </select>
                        </div>
                    </div>


                    <div class="outDiv" style="clear:left;margin-top:20px;">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>奖金方式：</label>
                        <div  class="col-sm-2 checkbox"  ng-show="baseInfo.profitType=='1'" > 固定金额</div>
                        <div  class="col-sm-2 checkbox"  ng-show="baseInfo.profitType=='2'" > 按比例发放</div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>奖励要求：</label>
                        <div class="col-sm-3" style="float:left;height:40px;line-height:40px;">
                            <select class="form-control" ng-model="baseInfo.status" ng-options="x.value as x.text for x in statusList">
                            </select>
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;" ng-show="baseInfo.profitType==1">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>保单总奖金：</label>
                        <div class="col-sm-3" style="float:left;height:40px;line-height:40px;">
                            <input type="text" ng-model="baseInfo.totalBonus" class="form-control" style="width:auto;display:inline-block;" required>元
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;" ng-show="baseInfo.profitType==2">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>保单总奖金： </label>

                        <div class="col-sm-3" style="float:left;height:40px;line-height:40px;">
                            <input type="text" ng-model="baseInfo.totalBonus" class="form-control" style="width:auto;display:inline-block;" required>%
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;"  ng-show="baseInfo.profitType==1">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>公司截留：</label>
                        <div class="col-sm-3" style="float:left;height:40px;line-height:40px;">
                            <input type="text" ng-model="baseInfo.companyBonus" class="form-control" style="width:auto;display:inline-block;" required>元
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;"  ng-show="baseInfo.profitType==2">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>公司截留：</label>
                        <div class="col-sm-3" style="float:left;height:40px;line-height:40px;">
                            <input type="text" ng-model="baseInfo.companyBonus" class="form-control" style="width:auto;display:inline-block;" required>%
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;"  ng-show="baseInfo.profitType==1">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>品牌截留：</label>
                        <div class="col-sm-3" style="float:left;height:40px;line-height:40px;">
                            <input type="text" ng-model="baseInfo.orgBonus" class="form-control" style="width:auto;display:inline-block;" required>元
                        </div>
                    </div>

                    <div class="outDiv" style="clear:left;margin-top:20px;"  ng-show="baseInfo.profitType==2">
                        <label style="float:left;width:30%;text-align:center;height:40px;line-height:40px;"><i class="red_req">*</i>品牌截留：</label>
                        <div class="col-sm-3" style="float:left;height:40px;line-height:40px;">
                            <input type="text" ng-model="baseInfo.orgBonus" class="form-control" style="width:auto;display:inline-block;" required>%
                        </div>
                    </div>
						
						<div style="clear:left;margin-top:40px;">
							&nbsp;
						</div>
						
						<div style="clear:left;margin-top:40px;">
							<label class="col-sm-2 control-label"></label>
							<div class="col-sm-6">
									<button class="btn btn-primary btn-mr20" type="button" ng-disabled='horizontal.$invalid' ng-click='saveInsurance()'>确定</button>
									<button class="btn btn-primary4 " type="button" ng-click='cancel()'>返回</button>
							</div>
						</div>
					</div>
				
			</div>
        </form>
    </div>
    
</div>